package com.android.dumiaogou.fragment.group;


import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.FragmentActivity;
import android.support.v7.widget.GridLayoutManager;
import android.support.v7.widget.Toolbar;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;

import com.android.dumiaogou.R;
import com.android.dumiaogou.fragment.BaseLazyFragment;
import com.android.dumiaogou.utils.ObjectUtils;
import com.android.dumiaogou.view.recycleview.CustomRecycleView;

import butterknife.BindView;
import butterknife.ButterKnife;

/**
 * App首页
 */

public class Fragment_Group extends BaseLazyFragment  {

    @BindView(R.id.click_resetnetwork_msg)
    TextView clickResetnetworkMsg;
    @BindView(R.id.main_top_bg)
    Toolbar mainTopBg;
    private View view;
    private FragmentActivity mcontext;
    private LayoutInflater inflater;
    private boolean networkConnected;


    private CustomRecycleView mRecyclerView;

    private int page = 1;

    private GridLayoutManager mGridLayoutManager ;

    public Fragment_Group() {
    }


    public static Fragment_Group newInstance() {
        Fragment_Group fragment = new Fragment_Group();
        Bundle args = new Bundle();

        fragment.setArguments(args);
        return fragment;
    }

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        if (getArguments() != null) {

        }
    }


    @Override
    protected void initPrepare() {
    }


    @Override
    protected void onInvisible() {

    }

    @Override
    protected void initData() {
        networkConnected = ObjectUtils.isNetworkConnected(mcontext);
    }


    @Override
    protected View initView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
        this.inflater = inflater;
        view = inflater.inflate(R.layout.layout_recycle_refresh, container, false);
        ButterKnife.bind(this, view);
        mcontext = getActivity();
        mainTopBg.setVisibility(View.GONE);
        initUI();
        return view;
    }


    /**
     * 控件初始化
     */
    private void initUI() {
        mRecyclerView = (CustomRecycleView) view.findViewById(R.id.listView);
        initRecycle();
        ReFreshData();
    }

    private void initRecycle() {

    }
    /**
     * 刷新
     */
    private void ReFreshData() {


    }









}



